package com.zmj.sy.mom.srv.aps.bean.bo.ado;

import com.zmj.sy.mom.srv.aps.bean.bo.ApsWeekDay;
import com.zmj.sy.mom.srv.aps.bean.bo.ApsWeekDayWrap;
import com.zmj.sy.mom.srv.aps.bean.entity.aps.AdoWorkDetail;
import com.zmj.sy.mom.srv.aps.utils.Comment;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;

@Getter
@Setter
public class AdoTask extends AdoStep {
    private Integer id;

    @Comment("消费状态 1未消费 2部分消费 3全部消费")
    private Integer consumerStatus;

    @Comment("消费数量")
    private BigDecimal consumerCount;

    @ApiModelProperty("状态 1-不排产 2-可排产 3-排产中 4-可重排 5-排产完成")
    private Integer status;

    private final AdoWorkDetail workDetail;

    private AdoWorkDetailTemp workDetailTemp;

    private List<ApsWeekDay> startMachineCalendar = new ArrayList<>();

    private List<ApsWeekDayWrap> all = new ArrayList<>();

    public AdoTask(AdoWorkDetail dw){
        workDetail = dw;
    }

    @Override
    public LocalDateTime getEndTime() {
        return workDetail.getPlanEndDateTime();
    }


}
